	function indexHideSubMenu(li) {
		var menuPlus =li.getElementsByTagName("span")[0];
		menuPlus.setAttribute("class","glyphicon glyphicon-plus");
		var subMenu = li.getElementsByTagName("ul")[0]; 
		subMenu.style.display = "none"; 
	}
function indexDisplaySubMenu(li) {
		li.focus();
	    var subMenu = li.getElementsByTagName("ul")[0]; 
		var menuPlus =li.getElementsByTagName("span")[0];
		var liArray = document.getElementsByClassName("dropdown1");
		liLength = liArray.length;
		for(var i=0;i<liLength;i++){
			
			indexHideSubMenu(liArray[i]);
		}
		
		menuPlus.setAttribute("class","glyphicon glyphicon-minus");
		//获取li的位置
		var left = li.offsetLeft;
		var screenWidth=document.body.clientWidth;
		var width=li.offsetWidth;
		if(left>screenWidth/2){
			subMenu.style.display = "block"; 
			subMenu.style.float="right";
			var rightlength=screenWidth-left-width;
			subMenu.style.paddingRight=rightlength+"px";
			subMenu.style.zIndex="9999";
		}else{
			subMenu.style.display = "block"; 
			subMenu.style.paddingLeft=left+"px";
			subMenu.style.zIndex="9999";
		}
		
	} 

	function displaySubMenu(li) {
		var subMenu = li.getElementsByTagName("ul")[0]; 
		//获取li的位置
		var left = li.offsetLeft;
		var screenWidth=document.body.clientWidth;
		var width=li.offsetWidth;
		if(left>screenWidth/2){
			subMenu.style.display = "block"; 
			subMenu.style.float="right";
			var rightlength=screenWidth-left-width;
			subMenu.style.right=rightlength+"px";
			subMenu.style.zIndex="9999";
		}else{
			subMenu.style.display = "block"; 
			subMenu.style.left=left+"px";
			subMenu.style.zIndex="9999";
		}
	} 
	function hideSubMenu(li) { 
		var subMenu = li.getElementsByTagName("ul")[0]; 
		subMenu.style.display = "none"; 
	}
	/*定时器变量*/
	var f;
	/*一共有几个图片进行切换*/
	var len;
	/*每个底图显露出来的宽度*/
	var width;
	function initPic(){
		len= $(".featureitem").length-1;
		var i=len;
		f = window.setInterval(function(){
			if(i<0){
				i=len;
			}
			/*设置当前图片的宽度*/
			$(".featureitem:eq("+i+")").css("width","1160px");
			$(".featureitem:gt("+i+")").css("width",width+"px");
			$(".featureitem:lt("+i+")").css("width",width+"px");
			i--;
		}, 2000);
	}
	function showPic(obj){
		window.clearInterval(f);
		$(obj).css("width","1160px");
		$(obj).prevAll().css("width",width+"px");
		$(obj).nextAll().css("width",width+"px");
	}